home *** CD-ROM | disk | FTP | other *** search
/ Champak 141 / (Vol 141) Oct 17 2011.iso / Games / despereaux-swings.swf / scripts / GameLogo.as < prev    next >
Encoding:
Text File  |  2011-10-17  |  987 b   |  50 lines

  1. package
  2. {
  3.    import flash.display.MovieClip;
  4.    
  5.    [Embed(source="/_assets/assets.swf", symbol="GameLogo")]
  6.    public dynamic class GameLogo extends MovieClip
  7.    {
  8.        
  9.       
  10.       public var rd:*;
  11.       
  12.       public var year:*;
  13.       
  14.       public var today:*;
  15.       
  16.       public var month:*;
  17.       
  18.       public var nowplaying:*;
  19.       
  20.       public var day:*;
  21.       
  22.       public function GameLogo()
  23.       {
  24.          super();
  25.          addFrameScript(0,frame1,1,frame2);
  26.       }
  27.       
  28.       internal function frame1() : *
  29.       {
  30.          stop();
  31.          year = 2008;
  32.          month = 12 - 1;
  33.          day = 19;
  34.          rd = new Date(year,month,day);
  35.          today = new Date();
  36.          nowplaying = today >= rd;
  37.          trace("nowplaying: " + nowplaying);
  38.          if(nowplaying)
  39.          {
  40.             gotoAndStop(2);
  41.          }
  42.       }
  43.       
  44.       internal function frame2() : *
  45.       {
  46.          stop();
  47.       }
  48.    }
  49. }
  50.